<?php
Yii::app ()->clientScript->registerCoreScript ( 'jquery' );
Yii::app ()->clientScript->registerScriptFile ( "/js/admin/main.js" );
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<meta name="language" content="en" />
	<link rel="shortcut icon" href="/css/admin/images/favicon.ico" type="image/x-icon">
	<!-- blueprint CSS framework -->
	<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/admin/screen.css" media="screen, projection" />
	<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/admin/print.css" media="print" />
	<!--[if lt IE 8]>
	<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/admin/ie.css" media="screen, projection" />
	<![endif]-->

	<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/admin/main.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/admin/form.css" />
	<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/admin/style-admin.css" />

	<title><?php echo CHtml::encode($this->pageTitle); ?></title>
</head>

<body>

<div class="container" id="page">

	<div id="header">
		<div id="logo"><?php echo CHtml::encode(Yii::app()->name); ?></div>
	</div><!-- header -->

	<div id="mainmenu">
		<?php $this->widget('zii.widgets.CMenu',array(
			'items'=>array(
				array('label'=>'Пользователи', 'url'=>array('users/admin')),
				//array('label'=>'Сообщества', 'url'=>array('groups/admin')),
				array('label'=>'Сообщества', 'url'=>'#', 'items'=>array(
					array('label'=>'Группы', 'url'=>array('groups/admin')),
					array('label'=>'Мероприятия', 'url'=>array('events/admin')),
				)),
				array('label'=>'Страны', 'url'=>array('country/admin')),
				array('label'=>'Статика', 'url'=>'#', 'items'=>array(
					array('label'=>'Статичные страницы', 'url'=>array('content/admin')),
					array('label'=>'Баннеры', 'url'=>array('banner/admin')),
					array('label'=>'Конфигурации', 'url'=>array('site/config')),
				)),
				
				array('label'=>'Выход ('.Yii::app()->user->name.')', 'url'=>array('site/logout'), 'visible'=>!Yii::app()->user->isGuest)
			),
		)); ?>
	</div><!-- mainmenu -->

	<?php $this->widget('zii.widgets.CBreadcrumbs', array(
		'homeLink'=> CHtml::openTag('li', array('class'=>'first')) . CHtml::link('Главная', '/admin') . CHtml::closeTag('li')."\n",
		'links'=>$this->breadcrumbs,
	)); ?><!-- breadcrumbs -->

	<?php echo $content; ?>

	<div id="footer">
		Copyright &copy; <?php echo date('Y'); ?> | <?php echo Yii::app()->name;?>.<br/>
		Все права защищены.<br/>
	</div><!-- footer -->

</div><!-- page -->

</body>
</html>